<div class="fl cat" id="cat">            
    <ul id="browser" class="filetree treeview">
        <li class="open collapsable lastCollapsable">
            <div class="hitarea open-hitarea collapsable-hitarea lastCollapsable-hitarea"></div>
            <span class="folder"><a href="#" class="">所有分类</a></span>
            <ul>
            <?php foreach ($data['children'] as $item) { ?>
                    <li id="<?php echo $item['id']; ?>" class="<?php if(!isset($item['leaf'])): ?>hasChildren expandable<?php else: ?>collapsable<?php endif ?>">
                        <div class="hitarea hasChildren-hitarea  collapsable-hitarea"></div>
                        <span class="folder"><a href="/admin/category/manage?id=<?php echo $item['id'];?>"><?php echo $item['name'] ?></a></span>
                        <?php
                        if (isset($item['children'])) {
                            if (is_array($item['children'])) {
						?>
                                <ul style="display: none;"> 
						<?php
                                foreach ($item['children'] as $sonItem) {
                                    if (isset($sonItem['leaf'])) {
                                        ?>
                                            <li id="<?php echo $sonItem['id'];?>"><span class="file"><a href="/admin/category/manage?id=<?php echo $sonItem['id'] ?>"><?php echo $sonItem['name'] ?></a></span></li>
                                        <?php
                                    } else {
                                        ?>
                    <li id="<?php echo $sonItem['id']; ?>" class="<?php if(!isset($sonItem['leaf'])): ?>collapsable<?php else: ?>expandable<?php endif ?>">
                                        <div class="hitarea hasChildren-hitarea expandable-hitarea"></div>
                                        <span class="folder"><a href="/admin/category/manage?id=<?php echo $sonItem['id'];?>"><?php echo $sonItem['name'] ?></a></span>
                                        <ul style="display: none; ">
                                            <?php
                                            if (isset($sonItem['children'])) {
                                                if (is_array($sonItem['children'])) {
                                                    foreach ($sonItem['children'] as $sonsonItem) {
                                                        if (isset($sonsonItem['leaf'])) {
                                                            ?>
                                                            <li id="<?php echo $sonsonItem['id']; ?>"><span class="file"><a href="/admin/category/manage?id=<?php echo $sonsonItem['id'] ?>"><?php echo $sonsonItem['name'] ?></a></span></li>
                                                                    <?php
                                                                }
                                                            }
                                                        }
                                                    }
                                                    ?>
                                        </ul>
									</li>
                                        <?php
                                    }
                                }
								?>
								</ul>
							<?php
                            }
                        }
                        ?>

                    </li>
<?php } ?>

                </ul>
            <!--<ul>
                <li id="27" class="collapsable">
                    <div class="hitarea collapsable-hitarea"></div>
                    <span class="folder"><a href="">合作伙伴</a></span>
                </li>
                <li id="28" class="hasChildren expandable">
                    <div class="hitarea hasChildren-hitarea expandable-hitarea"></div>
                    <span class="folder"><a href="" class="">经典项目</a></span>
                    <ul style="display: none;">
                        <li id="49"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=49">北京地区</a></span></li>
                        <li id="50"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=50">天津地区</a></span></li>
                        <li id="51" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=51">河北地区</a></span></li>
                    </ul>
                </li>
                <li id="29" class="hasChildren expandable">
                    <div class="hitarea hasChildren-hitarea expandable-hitarea"></div>
                    <span class="folder"><a href="/admin/category/setup.html?do=edit&amp;id=29" class="">联系我们</a></span>
                    <ul style="display: none;">
                        <li id="52" class="expandable">
                            <div class="hitarea expandable-hitarea"></div>
                            <span class="folder"><a href="/admin/category/manage.html?do=edit&amp;id=52">诚聘英才</a></span>
                            <ul style="display: none;">
                                <li id="53"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=53">销售工程师</a></span></li>
                                <li id="54" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=54">工程、项目信息采集员</a></span></li>
                            </ul>
                        </li>
                        <li id="55" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=55">地址、电话</a></span></li>
                    </ul>
                </li>
                <li id="23" class="hasChildren collapsable">
                    <div class="hitarea hasChildren-hitarea collapsable-hitarea"></div>
                    <span class="folder"><a href="/admin/category/setup.html?do=edit&amp;id=23" class="">关于Unical</a></span>
                    <ul style="">
                        <li id="31"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=31">品牌介绍</a></span></li>
                        <li id="32"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=32">公司历史</a></span></li>
                        <li id="33" class="collapsable lastCollapsable">
                            <div class="hitarea collapsable-hitarea lastCollapsable-hitarea"></div>
                            <span class="folder hover"><a href="/admin/category/manage.html?do=edit&amp;id=33">资质、证书</a></span>
                            <ul style="">
                                <li id="34"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=34">实验室CE认证</a></span></li>
                                <li id="35"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=35">EVE05 24CTFS 认证</a></span></li>
                                <li id="36"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=36">ALKON冷凝炉检验报告</a></span></li>
                                <li id="37" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=37">ASME认证</a></span></li>
                            </ul>
                        </li>
                    </ul>
                </li>
                <li id="26" class="hasChildren expandable">
                    <div class="hitarea hasChildren-hitarea expandable-hitarea"></div>
                    <span class="folder"><a href="/admin/category/setup.html?do=edit&amp;id=26" class="">客户服务</a></span>
                    <ul style="display: none; ">
                        <li id="48" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=48">常见问题及解决方法</a></span></li>
                    </ul>
                </li>
                <li id="25" class="hasChildren expandable">
                    <div class="hitarea hasChildren-hitarea expandable-hitarea"></div>
                    <span class="folder"><a href="/admin/category/setup.html?do=edit&amp;id=25">产品中心</a></span>
                    <ul style="display: none; ">
                        <li id="40"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=40">供暖产品</a></span></li>
                        <li id="41" class="expandable">
                            <div class="hitarea expandable-hitarea"></div>
                            <span class="folder"><a href="/admin/category/manage.html?do=edit&amp;id=41">壁挂炉</a></span>
                            <ul style="display: none; ">
                                <li id="42"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=42">燃气壁挂炉</a></span></li>
                                <li id="43" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=43">冷凝壁挂炉</a></span></li>
                            </ul>
                        </li>
                        <li id="44"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=44">燃气落地模块锅炉</a></span></li>
                        <li id="45"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=45">燃气冷凝落地炉</a></span></li>
                        <li id="46"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=46">燃木真火锅炉</a></span></li>
                        <li id="47" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=47">秸秆锅炉</a></span></li>
                    </ul>
                </li>
                <li id="24" class="hasChildren expandable lastExpandable">
                    <div class="hitarea hasChildren-hitarea expandable-hitarea lastExpandable-hitarea"></div>
                    <span class="folder"><a href="/admin/category/setup.html?do=edit&amp;id=24">新闻中心</a></span>
                    <ul style="display: none; ">
                        <li id="38"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=38">Unical集团</a></span></li>
                        <li id="39" class="last"><span class="file"><a href="/admin/category/manage.html?do=edit&amp;id=39">Unical中国</a></span></li>
                    </ul>
                </li>
            </ul>
			</li>
    </ul>-->

</div>

<script>
    $(document).ready(function() {
        $("#browser").treeview();
    });
    setTimeout(function() {
        $("#cat").height($(window).height() - $("#top").height() - $("#menu").height());
        $("#cat").css('overflow-y', 'scroll');
        $("#browser").treeview();
    }, 1000);
</script>
